<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>拟态鼠标</title>
    <style>
        *{
            margin: 0;
            padding: 0;
        }
        body{
            display: flex;
            align-items: center;
            justify-content: center;
            height: 100vh;
            background: #efeeee;
        }
        .container{
            display: flex;
            /* 一行中的元素平均分配宽度 */
            justify-content: space-around;
            align-items: center;
            /* 一行放不下时候自动换行 */
            flex-wrap: wrap;
            width: 700px;
            height: 600px;
        }
        .container .box{
            display: flex;
            justify-content: space-around;
            align-items: center;
            /* 元素垂直排列  就是让包含图片的div 和文字垂直排列 */
            flex-direction: column;
            width: 100px;
            height: 140px;
            margin:20px;
            cursor: pointer;
        }
        .container .box .img{
            /* 让图片在盒子里面垂直+水平居中 */
            display: flex;
            justify-content: center;
            align-items: center;
            width: 100px;
            height: 100px;
            border-radius: 20px;
            box-shadow: 18px 18px 30px rgba(0,0,0,.2),
                        -18px -18px 30px rgba(255,255,255,.1);
            transition: all .2s ease-in-out;
        }
        .container .box .img img{
            width: 60px;
            transition: all .2s ease-in-out;
        }
        .container .box p{
            color: slategray;
        }
        .container .box .img:hover{
            box-shadow: 0 0 0 rgba(0, 0, 0, .2),
                        0 0 0 rgba(255, 255, 255, .8),
                        inset 18px 18px 30px rgba(0, 0, 0, .1),
                        inset -18px -18px 30px rgba(255, 255, 255, 1);
        }
        .container .box .img:hover img{
            width: 58px;
        }
    </style>
</head>
<body>
    <div class="container">
        <div class="box">
            <div class="img"><img src="../images/1.png" alt=""></div>
            <p>录音机</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/2.png" alt=""></div>
            <p>通讯录</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/3.png" alt=""></div>
            <p>电话</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/4.png" alt=""></div>
            <p>短信</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/5.png" alt=""></div>
            <p>浏览器</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/6.png" alt=""></div>
            <p>相机</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/7.png" alt=""></div>
            <p>相册</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/8.png" alt=""></div>
            <p>哔哩哔哩</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/9.png" alt=""></div>
            <p>日历</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/10.png" alt=""></div>
            <p>时钟</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/11.png" alt=""></div>
            <p>Youtube</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/12.png" alt=""></div>
            <p>Feacbook</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/13.png" alt=""></div>
            <p>微信</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/14.png" alt=""></div>
            <p>QQ</p>
        </div>
        <div class="box">
            <div class="img"><img src="../images/15.png" alt=""></div>
            <p>微博</p>
        </div>
    </div>
</body>
</html>